package qmsz.api.utils;

public enum ResponseCode {
	SUCCESS(0, "成功"),
	FAIL_AGENCY(10001, "操作名义错误"),
	FAIL_AUTH(10002, "鉴权错误"),
	FAIL_SIGN(10003, "签名错误"),
	FAIL_PARAM(10004, "参数错误"),
	FAIL_SQL_INSERT(10005, "新纪录添加失败"),
	FAIL_SQL_SEARCH(10005, "无查询结果"),
	FAIL_SQL_UPDATE(10005, "记录更新失败"),
	FAIL_SQL_REMOVE(10005, "记录移除失败"),
	FAIL_NESTED_REQUEST(10006, "嵌套请求错误"),
	FAIL_ABUSE(10007, "操作次数过多");
	
	private int code;
	private String msg;
	
	private ResponseCode(int code, String msg) {
		this.code = code;
		this.msg = msg;
	}
	
	public int getCode() {
		return code;
	}
	
	public String getMsg() {
		return msg;
	}
}
